<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <link rel="stylesheet" href="./css/index.css">

</head>

<body>
    <header>
        <h1>可视化展板-Echarts</h1>
        <p class="showTime">时间</p>
    </header>
    <div class="mainbox">
        <div class="childbox">
            <div class="panel bar">
                <h2 class="title">柱形图-就业行业</h2>
                <div class="chart"></div>
                <div class="panel-footer"></div>
            </div>
            <div class="panel line">
                <h2 class="title">
                    折线图-人员变化
                    <a class="year" href="javascript:;">2020</a>
                    <a class="year" href="javascript:;">2021</a>
                </h2>
                <div class="chart"></div>
                <div class="panel-footer"></div>
            </div>
            <div class="panel pie">
                <h2 class="title">饼形图-年龄分布</h2>
                <div class="chart"></div>
                <div class="panel-footer"></div>
            </div>
        </div>
        <div class="childbox">
            <div class="no">
                <div class="no-hd">
                    <ul>
                        <li>125811</li>
                        <li>100000</li>
                    </ul>
                </div>
                <div class="no-bd">
                    <ul>
                        <li>前端需求人数</li>
                        <li>市场供应人数</li>
                    </ul>
                </div>
            </div>
            <div class="map">
                <div class="map1"></div>
                <div class="map2"></div>
                <div class="map3"></div>
                <div class="chart"></div>
            </div>
        </div>
        <div class="childbox">
            <div class="panel bar2">
                <h2 class="title">柱形图-就业工具</h2>
                <div class="chart"></div>
                <div class="panel-footer"></div>
            </div>
            <div class="panel line2">
                <h2 class="title">折线图-播放量</h2>
                <div class="chart"></div>
                <div class="panel-footer"></div>
            </div>
            <div class="panel pie2">
                <h2 class="title">饼形图-地区分布</h2>
                <div class="chart"></div>
                <div class="panel-footer"></div>
            </div>
        </div>
    </div>
    <script src="./js/flexible.js"></script>
    <script src="./js/echarts.min.js"></script>
    <script src="./js/china.js"></script>
    <script src="./js/index.js"></script>
    <script>
        function time() {
            var currentDate = new Date();
            var year = currentDate.getFullYear();
            var month = currentDate.getMonth() + 1;
            var day = currentDate.getDate();
            var hours = currentDate.getHours();
            var minutes = currentDate.getMinutes();
            var seconds = currentDate.getSeconds();
            // 格式化时间
            var currentTimeString = '当前时间：' + year + '年' + month + '月' + day + '号' + hours + '时' + minutes + '分' + seconds + '秒';
            document.querySelector('.showTime').innerText = currentTimeString;
        }
        // 先调用一次，不然页面会出现一秒的延迟
        time();
        // 每秒更新一次时间
        setInterval(time, 1000);

    </script>

</body>

</html>